import bank from "@/assets/utils/bank";
import axiosPlugin from "@/assets/utils/axios-pack.js"; 

let Axios = axiosPlugin.Axios

export default {
	getSource: ({ commit, dispatch, state}, {loadFirst = true, }) => {
		let config = {
			baseURL:'http://admin.mumway.com/api/index/',
		}
		Axios.post('getchannel', {}, config)
		.then(function (response) {
			console.log(response)
			// commit("SET_SOURCE",);
		})
	},

	getCity:({ commit, dispatch, state}, {loadFirst = true}) => {
		let config = {
			baseURL:'http://admin.mumway.com/index/activity/cityList',
		}
		Axios.post('cityList', {}, config)
		.then(response=>{
			if (response.success) {
				commit("SET_CITY", response.data);
			}
		})
	},

	setSource:({ commit, dispatch, state}, {loadFirst = true, source}) => {
		commit("SET_SOURCE", source);
	}
}

// http://admin.mumway.com/index/activity/cityList